package top.system.dept.pojo;

import java.io.Serializable;

/**
 * @ClassName: ApplyItem
 * @Author: Amosen
 * @Since: 2021/5/21
 */

// 每个订单中所对应的物品
public class ApplyItem implements Serializable {

    private static final long serialVersionUID = 3609712077645110123L;

    private Integer id;

    private Integer iId;

    private String name;

    private Integer num;

    private String pic;

    public ApplyItem() {
    }

    public ApplyItem(Integer id, Integer iId, String name, Integer num, String pic) {
        this.id = id;
        this.iId = iId;
        this.name = name;
        this.num = num;
        this.pic = pic;
    }

    public ApplyItem load(Item item, Integer num) {
        this.iId = item.getId();
        this.name = item.getName();
        this.num = num;
        this.pic = item.getItemPic();
        return this;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Integer getiId() {
        return iId;
    }

    public void setiId(Integer iId) {
        this.iId = iId;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Integer getNum() {
        return num;
    }

    public void setNum(Integer num) {
        this.num = num;
    }

    public String getPic() {
        return pic;
    }

    public void setPic(String pic) {
        this.pic = pic;
    }

    @Override
    public String toString() {
        return "ApplyItem{" +
                "id=" + id +
                ", iId=" + iId +
                ", name='" + name + '\'' +
                ", num=" + num +
                ", pic='" + pic + '\'' +
                '}';
    }
}
